import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart';

class RoundedRippleWidget extends StatelessWidget {
  final String svgAsset;
  final double padding;
  final double size;
  final VoidCallback onTap;

  const RoundedRippleWidget(
      {Key key,
      @required this.svgAsset,
      this.padding = 8,
      this.size = 16,
      this.onTap})
      : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Material(
      color: Colors.transparent,
      child: InkWell(
        onTap: onTap,
        // splashColor: Colors.white54,
        // highlightColor: Colors.white30,
        customBorder: CircleBorder(),
        child: Padding(
          padding: EdgeInsets.all(padding),
          child: SvgPicture.asset(
            svgAsset,
            width: size,
            height: size,
          ),
        ),
      ),
    );
  }
}
